import java.util.HashSet;
import java.util.Iterator;
import java.util.Scanner;
import java.util.Set;

public class Main {
    //坏键盘打字
    public static void fun(String all,String good){
        Set<Character>set=new HashSet<>();
        for(char part:all.toUpperCase().toCharArray()){
            set.add(part);
        }
        for(char goodPart:good.toUpperCase().toCharArray()){
            if(set.contains(goodPart)){
                set.remove(goodPart);
            }
        }
        Iterator<Character> it= set.iterator();{
            while (it.hasNext()){
                Character bad=it.next();
                System.out.print(bad);
            }
        }

    }

    public static void main(String[] args) {
        Scanner in=new Scanner(System.in);
        while(in.hasNextLine()){
            String s1=in.nextLine();
            String s2=in.nextLine();
            fun(s1,s2);
        }
    }
}
